<?php
//用curl发送get请求
$url='http://'.$_SERVER['SERVER_NAME'].$_SERVER["REQUEST_URI"]; 
$server=dirname($url)."/server.php";

$curl=curl_init();//初始化

//设置请求的参数
curl_setopt($curl, CURLOPT_URL, $server);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_HEADER, 0);

$output = curl_exec($curl);//执行
curl_close($curl);//释放
print_r($output);//输出